<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.3.1"/>
<title>APR (Airport Rhapsody): monAirportRhapsodyPa.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">APR (Airport Rhapsody)
   &#160;<span id="projectnumber">1.0</span>
   </div>
   <div id="projectbrief">Implementation based on monitors</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.3.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('mon_airport_rhapsody_pa_8h.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#define-members">Macros</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">monAirportRhapsodyPa.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Problem name: Airport rhapsody.  
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &lt;stdbool.h&gt;</code><br/>
</div>
<p><a href="mon_airport_rhapsody_pa_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:af1c1e08a6a3fe570b300d3ae76855f03"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="af1c1e08a6a3fe570b300d3ae76855f03"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#af1c1e08a6a3fe570b300d3ae76855f03">FDBTC</a>&#160;&#160;&#160;0</td></tr>
<tr class="memdesc:af1c1e08a6a3fe570b300d3ae76855f03"><td class="mdescLeft">&#160;</td><td class="mdescRight">the passenger has this airport as her final destination and has bags to collect <br/></td></tr>
<tr class="separator:af1c1e08a6a3fe570b300d3ae76855f03"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab5e7cfff2f9ad731ec15123d109142bb"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab5e7cfff2f9ad731ec15123d109142bb"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#ab5e7cfff2f9ad731ec15123d109142bb">FDNBTC</a>&#160;&#160;&#160;1</td></tr>
<tr class="memdesc:ab5e7cfff2f9ad731ec15123d109142bb"><td class="mdescLeft">&#160;</td><td class="mdescRight">the passenger has this airport as her final destination with no bags to collect <br/></td></tr>
<tr class="separator:ab5e7cfff2f9ad731ec15123d109142bb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af2d45c544b3d85856618b259d44882d6"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="af2d45c544b3d85856618b259d44882d6"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#af2d45c544b3d85856618b259d44882d6">INTRAN</a>&#160;&#160;&#160;2</td></tr>
<tr class="memdesc:af2d45c544b3d85856618b259d44882d6"><td class="mdescLeft">&#160;</td><td class="mdescRight">the passenger is in transit <br/></td></tr>
<tr class="separator:af2d45c544b3d85856618b259d44882d6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7ebc9a785e5ab85457c98595aac81589"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a7ebc9a785e5ab85457c98595aac81589"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a7ebc9a785e5ab85457c98595aac81589">YES</a>&#160;&#160;&#160;0</td></tr>
<tr class="memdesc:a7ebc9a785e5ab85457c98595aac81589"><td class="mdescLeft">&#160;</td><td class="mdescRight">the passenger has collected all her bags <br/></td></tr>
<tr class="separator:a7ebc9a785e5ab85457c98595aac81589"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a996bde01ecac342918f0a2c4e7ce7bd5"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a996bde01ecac342918f0a2c4e7ce7bd5"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a996bde01ecac342918f0a2c4e7ce7bd5">NO</a>&#160;&#160;&#160;1</td></tr>
<tr class="memdesc:a996bde01ecac342918f0a2c4e7ce7bd5"><td class="mdescLeft">&#160;</td><td class="mdescRight">the passenger has not yet collected all her bags <br/></td></tr>
<tr class="separator:a996bde01ecac342918f0a2c4e7ce7bd5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa6b38d492364d98453284934ed7caee9"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aa6b38d492364d98453284934ed7caee9"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#aa6b38d492364d98453284934ed7caee9">MB</a>&#160;&#160;&#160;3</td></tr>
<tr class="memdesc:aa6b38d492364d98453284934ed7caee9"><td class="mdescLeft">&#160;</td><td class="mdescRight">the passenger has missing bags <br/></td></tr>
<tr class="separator:aa6b38d492364d98453284934ed7caee9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ab595b8de1481b370d9cf10cf9e9e9f96"><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#ab595b8de1481b370d9cf10cf9e9e9f96">whatShouldIDo</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:ab595b8de1481b370d9cf10cf9e9e9f96"><td class="mdescLeft">&#160;</td><td class="mdescRight">What should I do.  <a href="#ab595b8de1481b370d9cf10cf9e9e9f96">More...</a><br/></td></tr>
<tr class="separator:ab595b8de1481b370d9cf10cf9e9e9f96"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad0d7923afc9473274a40b6f8e05c24b7"><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#ad0d7923afc9473274a40b6f8e05c24b7">goCollectABag</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:ad0d7923afc9473274a40b6f8e05c24b7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Go collect a bag.  <a href="#ad0d7923afc9473274a40b6f8e05c24b7">More...</a><br/></td></tr>
<tr class="separator:ad0d7923afc9473274a40b6f8e05c24b7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4007192c86fbafe0df79b0ca370c19db"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a4007192c86fbafe0df79b0ca370c19db">reportMissingBags</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:a4007192c86fbafe0df79b0ca370c19db"><td class="mdescLeft">&#160;</td><td class="mdescRight">Report missing bags.  <a href="#a4007192c86fbafe0df79b0ca370c19db">More...</a><br/></td></tr>
<tr class="separator:a4007192c86fbafe0df79b0ca370c19db"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5e8beada4b1bcb14e62322e2ac2cf81d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a5e8beada4b1bcb14e62322e2ac2cf81d">goHome</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:a5e8beada4b1bcb14e62322e2ac2cf81d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Go home.  <a href="#a5e8beada4b1bcb14e62322e2ac2cf81d">More...</a><br/></td></tr>
<tr class="separator:a5e8beada4b1bcb14e62322e2ac2cf81d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a50b13b2c0471978d62ab4fe967e41f7b"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a50b13b2c0471978d62ab4fe967e41f7b">takeABus</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:a50b13b2c0471978d62ab4fe967e41f7b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Take a bus.  <a href="#a50b13b2c0471978d62ab4fe967e41f7b">More...</a><br/></td></tr>
<tr class="separator:a50b13b2c0471978d62ab4fe967e41f7b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6d658470428d0231788b26d80304dd03"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a6d658470428d0231788b26d80304dd03">enterTheBus</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:a6d658470428d0231788b26d80304dd03"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enter the bus.  <a href="#a6d658470428d0231788b26d80304dd03">More...</a><br/></td></tr>
<tr class="separator:a6d658470428d0231788b26d80304dd03"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6874c82981cb92d46bc81bb4478f1e0a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a6874c82981cb92d46bc81bb4478f1e0a">leaveTheBus</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:a6874c82981cb92d46bc81bb4478f1e0a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Leave the bus.  <a href="#a6874c82981cb92d46bc81bb4478f1e0a">More...</a><br/></td></tr>
<tr class="separator:a6874c82981cb92d46bc81bb4478f1e0a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a693d95781c75a8d390a1190552a243d8"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="mon_airport_rhapsody_pa_8h.html#a693d95781c75a8d390a1190552a243d8">prepareNextLeg</a> (unsigned int k, unsigned int id)</td></tr>
<tr class="memdesc:a693d95781c75a8d390a1190552a243d8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Prepare next leg.  <a href="#a693d95781c75a8d390a1190552a243d8">More...</a><br/></td></tr>
<tr class="separator:a693d95781c75a8d390a1190552a243d8"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Problem name: Airport rhapsody. </p>
<p>(interface file)</p>
<p>Concept: António Rui Borges</p>
<p>Synchronization based on monitors. Both threads and the monitor are implemented using the pthread library which enables the creation of a monitor of the Lampson / Redell type.</p>
<p>Definition of the operations carried out by the passenger threads: </p>
<ul>
<li>what should I do </li>
<li>go collect a bag </li>
<li>report missing bags </li>
<li>go home </li>
<li>take a bus </li>
<li>enter the bus </li>
<li>leave the bus </li>
<li>prepare next leg.</li>
</ul>
<dl class="section author"><dt>Author</dt><dd>António Rui Borges - December 2013 </dd></dl>
</div><h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="a6d658470428d0231788b26d80304dd03"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void enterTheBus </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Enter the bus. </p>
<p>The passenger enters the bus that it is going to take her to the departure transfer terminal and occupies an available seat. If it is already packed full, she issues an error message. If she is the last one to board the bus for the ride, she informs the driver he may start the journey.</p>
<p>State should be saved.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ad0d7923afc9473274a40b6f8e05c24b7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned int goCollectABag </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Go collect a bag. </p>
<p>The passenger waits until she receives a call from the porter. She then checks if there is a bag on the belt conveyor that belongs to her. If so, she picks it up and updates the number of bags already recovered. If not, she updates statistical information. Upon exit, a decision is taken about her present situation.</p>
<p>State may be be saved twice. The first of the two only if there is a change of state of the passenger.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>YES</code>, if she has collected all her bags </dd>
<dd>
<code>NO</code>, if she has not yet collected all her bags </dd>
<dd>
<code>MB</code>, if she has missing bags </dd></dl>

</div>
</div>
<a class="anchor" id="a5e8beada4b1bcb14e62322e2ac2cf81d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void goHome </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Go home. </p>
<p>The passenger exits the airport.</p>
<p>However, before actually doing that, she waits for all other passengers being ready to either exit the airport or also enter the departure terminal and, if she is the very last passenger of the very last flight, she informs the bus driver that his day's work is finished.</p>
<p>State should be saved.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a6874c82981cb92d46bc81bb4478f1e0a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void leaveTheBus </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Leave the bus. </p>
<p>The passenger checks the bus occupation. If it is already empty, she issues an error message. The transit passenger leaves the bus that has taken her to the departure transfer terminal. If she is the last one to exit, she informs the driver he may start the journey back.</p>
<p>State should be saved.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a693d95781c75a8d390a1190552a243d8"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void prepareNextLeg </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Prepare next leg. </p>
<p>The passenger enters the departure terminal.</p>
<p>However, before actually doing that, she waits for all other passengers being ready to either exit the airport or also enter the departure terminal and, if she is the very last passenger of the very last flight, she informs the bus driver that his day's work is finished.</p>
<p>State should be saved.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a4007192c86fbafe0df79b0ca370c19db"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void reportMissingBags </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Report missing bags. </p>
<p>The passenger fills the form for missing bags.</p>
<p>State should be saved.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a50b13b2c0471978d62ab4fe967e41f7b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void takeABus </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Take a bus. </p>
<p>The transit passenger queues at the arrival transfer terminal to take a bus to the departure transfer terminal.</p>
<p>However, before waiting her turn, she informs the bus driver it is time to start boarding if the number of queueing passengers is equal to the number of seats in the bus.</p>
<p>State should be saved.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ab595b8de1481b370d9cf10cf9e9e9f96"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned int whatShouldIDo </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>What should I do. </p>
<p>The passenger descending from the plane decides what should she do according to her situation (has this airport as her final destination and has bags to collect / has this airport as her final destination with no bags to collect / is in transit) and updates statistical information.</p>
<p>If she is the very last passenger descending from the plane, she must inform the porter that a new plane has landed. If she is the very first passenger, she sets the number of the plane landing.</p>
<p>State should only be saved by the very first passenger descending from the plane.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">k</td><td>plane landing number </td></tr>
    <tr><td class="paramname">id</td><td>passenger identification</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>FDBTC</code>, if she has this airport as her final destination and has bags to collect </dd>
<dd>
<code>FDNBTC</code>, if she has this airport as her final destination with no bags to collect </dd>
<dd>
<code>INTRAN</code>, if she is in transit </dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="mon_airport_rhapsody_pa_8h.html">monAirportRhapsodyPa.h</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.3.1 </li>
  </ul>
</div>
</body>
</html>
